<template>
  <div class="company-quality">
    <p
      v-if="detailAll.supplier_info.company_qualification"
      class="btn check_allgoods j-companyAptitude"
      @click="showCompanyCode"
    >公司资质</p>
    <!-- 公司资质弹窗 -->
    <div class="code-dialog" v-if="detailAll.supplier_info">
      <van-popup
        v-model="dialogVisible"
        class="code-pop"
      >
      <div class="code-wrap">
        <img :src="detailAll.supplier_info.company_qualification" alt="" class="item_qrcode">
      </div>
      </van-popup>
    </div>
  </div>
</template>


<script>
import Vue from "vue";
export default Vue.extend({
  props: {
    detailAll: {
      type: Object,
    },
  },
  data() {
    return {
      dialogVisible: false,
    };
  },
  methods: {
    // 公司资质
    showCompanyCode() {
      this.dialogVisible = true;
    },
  },
});
</script>

<style  lang="scss">
  @import "src/styles/mixin";
  @import "src/styles/variables";
  .company-quality{
    .check_allgoods{
      border: 1px solid;
      border-radius: 24rpx;
      line-height: 44rpx;
    }
  }
  .code-dialog{
    background: #fff;
    position: relative;
    .code-pop{
      overflow:hidden;
      border-radius:20px;
      width:600px;
    }
    .code-wrap{
      padding:20px;
      .item_qrcode{
        display:block;
        width:100%;
        max-height:960px;
      }
    }
  }
</style>